#include "CTestServerSocketClient.h"
#include <iostream>
REGISTESOCKETCLIENT(CTestServerSocketClient, SOCKETCLIENT_TYPE_TEST, true);
void CTestServerSocketClient::OnConnect(int errCode)
{
    if (errCode != 0)
    {
        Shutdown();
        return;
    }
    char* data = new char[sizeof(SOCKETDESOBJ) + m_sckDes.dataSize];
    memcpy(data, &m_sckDes, sizeof(SOCKETDESOBJ));
    memcpy(data + sizeof(SOCKETDESOBJ), m_sckDes.data, m_sckDes.dataSize);
    SendDataDirect(data, sizeof(SOCKETDESOBJ) + m_sckDes.dataSize);
}
void CTestServerSocketClient::OnRead(int errCode) {}
void CTestServerSocketClient::OnClose(int errCode) {}
